//Accepted
#include <vector>
#include <set>
#include <algorithm>
#include <string>
#include <cmath>
#include <queue>
#include <map>
#include <iostream>
#include <list>
#include <deque>
#include <cstdio>
#include <cstring>
#include <cstdlib>
using namespace std;


int main (){
	//freopen("in.txt", "r", stdin);//freopen("out.txt", "w", stdout);
	int n, i, j, s, a[100], x;
	
	scanf("%d", &n);
	for(s=i=0, j=1;i<n;++i){
		scanf("%d", &x);
		if(x==j){
			a[s++]=i;
			++j;
		}
	}
	printf("%d\n", s);
	for(i=0;i<s;++i)printf("%d ", 2001+a[i]);
	
	return 0;
}
